package com.googlecode.struts2scope.scope.annotation.scanner;

import java.lang.reflect.Field;

import com.googlecode.struts2scope.scope.ScopeType;

public class FieldMetadata {

	private Field original;

	private ScopeType scopeType;
	
	private String key;
	
	public FieldMetadata(Field field, ScopeType scopeType, String key) {
		this.original = field;
		this.scopeType = scopeType;
		this.key = key == "" ? this.original.getName() : key;
	}
	
	public String getName() {
		return this.original.getName();
	}
	
	public ScopeType getScopeType() {
		return scopeType;
	}
	
	public String getKey() {
		return key;
	}
}
